/*    */ package com.cr.framework.web.service;
/*    */ 
/*    */ import com.cr.common.utils.CacheUtils;
/*    */ import java.util.Set;
/*    */ import org.apache.commons.lang3.ArrayUtils;
/*    */ import org.springframework.stereotype.Service;
/*    */ 
/*    */ @Service
/*    */ public class CacheService {
/*    */   public String[] getCacheNames() {
/* 24 */     String[] cacheNames = CacheUtils.getCacheNames();
/* 25 */     return (String[])ArrayUtils.removeElement((Object[])cacheNames, "sys-authCache");
/*    */   }
/*    */   
/*    */   public Set<String> getCacheKeys(String cacheName) {
/* 36 */     return CacheUtils.getCache(cacheName).keys();
/*    */   }
/*    */   
/*    */   public Object getCacheValue(String cacheName, String cacheKey) {
/* 48 */     return CacheUtils.get(cacheName, cacheKey);
/*    */   }
/*    */   
/*    */   public void clearCacheName(String cacheName) {
/* 58 */     CacheUtils.removeAll(cacheName);
/*    */   }
/*    */   
/*    */   public void clearCacheKey(String cacheName, String cacheKey) {
/* 69 */     CacheUtils.remove(cacheName, cacheKey);
/*    */   }
/*    */   
/*    */   public void clearAll() {
/* 77 */     String[] cacheNames = getCacheNames();
/* 78 */     for (String cacheName : cacheNames)
/* 80 */       CacheUtils.removeAll(cacheName); 
/*    */   }
/*    */ }


/* Location:              D:\tmp\creditorRights-admin\BOOT-INF\lib\creditorRights-framework-4.7.0.jar!\com\cr\framework\web\service\CacheService.class
 * Java compiler version: 8 (52.0)
 * JD-Core Version:       1.1.3
 */